package console;

import java.awt.*;
import java.awt.event.*;
import java.awt.geom.*;
import javax.swing.*;
/*
import javax.swing.JFrame;
import javax.swing.JButton;
import javax.swing.JPanel;
//import javax.swing.BorderLayout;
import java.awt.BorderLayout;
*/

public class Console extends JApplet {
    static JButton item;
    static JButton up;
    static JButton down;
    static JButton allCombo;
    static JButton upDownCombo;
    static SevenSegment sevenSegmentOnes;
    public Console() {
/*
        item = new JButton("item");
        up = new JButton("up");
        down = new JButton("down");
        allCombo = new JButton("all");
        upDownCombo = new JButton("up/down");
        JPanel buttonRow = new JPanel();
        JPanel buttonCombo = new JPanel();
        buttonRow.setLayout(new BorderLayout());
        buttonRow.add(item,BorderLayout.WEST);
        buttonRow.add(up,BorderLayout.CENTER);
        buttonRow.add(down,BorderLayout.EAST);
        setLayout(new BorderLayout());
        add(buttonRow,BorderLayout.CENTER);
        buttonCombo.add(allCombo,BorderLayout.WEST);
        buttonCombo.add(upDownCombo,BorderLayout.EAST);
        add(buttonCombo,BorderLayout.SOUTH);
*/

        //java.awt.image.BufferedImage image = new java.awt.image.BufferedImage(200,200);
//        java.awt.Image image = java.awt.Image.createImage();
//        java.awt.Frame f = new java.awt.Frame();
//        sevenSegmentOnes = new SevenSegment(f,200,200);
//        add(sevenSegmentOnes,BorderLayout.NORTH);
//        pack();
    }
/*
    public void addDisplay() {
        sevenSegmentOnes = new SevenSegment(this,200,200);
        add(sevenSegmentOnes,BorderLayout.NORTH);
    }
*/
    public static void main(String args[]) {
        JFrame f = new JFrame("Console");
        f.addWindowListener(new WindowAdapter() {
            public void windowClosing(WindowEvent e) {System.exit(0);}
        });

        JApplet applet = new Console();
        f.getContentPane().add("Center",applet);
//        applet.addDisplay();
        sevenSegmentOnes = new SevenSegment(applet,200,200);
        applet.add(sevenSegmentOnes,BorderLayout.NORTH);
        applet.init();
        f.pack();
        f.setSize(new Dimension(550,100));
        f.setVisible(true);
    }
}
